#include <iostream>
using namespace std;
#include <iomanip>
using std::setw;
#include <cmath>

double pi (double n);

int main()
{
    double n;
    cout << "input how many times to acc: \n";
    cin >> n;;
    cout << pi(n);
    return 0;

}

double pi (double n) 
{
	double s=0.0;
	for(int i=1;i<=n;i++) s=s+1.0/(i*i);
	return (sqrt(6*s));
}
